package com.colorlight.cloud.complete.entity.po;

import com.colorlight.cloud.complete.entity.enumerate.SensorType;
import com.colorlight.cloud.gateway.api.annotation.defaultValue;
import com.colorlight.cloud.gateway.api.annotation.percent;
import com.colorlight.cloud.gateway.api.message.constraint.basics.object.Trans;
import com.colorlight.iot.proto.complete.entity.CompleteEntity;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class SensorItem implements Trans<SensorItem, CompleteEntity.SensorItem> {

    /**
     * 传感器数据，真实数据x1000，后3位作为小数点后的值
     */
    @percent
    private Float data;

    /**
     * 传感器序号，如板载电压0，板载电压1（从0开始）
     */
    private Integer index;

    /**
     * 传感器类型
     */
    private SensorType sensorType;
}

